Skip to content

feat(url-to-frame-md): website capture → frame.md design system + showcase renderer - #2005

Closed
xuanruli wants to merge 1 commit into
feat/capture-shadow-by-computed-stylefrom
feat/url-to-frame-md
Closed

feat(url-to-frame-md): website capture → frame.md design system + showcase renderer#2005
xuanruli wants to merge 1 commit into
feat/capture-shadow-by-computed-stylefrom
feat/url-to-frame-md

Conversation

@xuanruli

@xuanruli xuanruli commented Jul 7, 2026

Copy link
Copy Markdown
Contributor

What

A toolkit (url-to-frame-md/) that turns a hyperframes capture of any website into a video-first design spec (frame.md) and a brand-dressed showcase board (showcase.png).

  • build-frame-from-capture.mjs — capture → frame.md: palette (incl. vivid secondary brand accents), two type ramps, spacing, radii, shadows, and video-usable components. Faithful to the capture.
  • verify-frame.mjs — L0/L1/L2 machine gates (schema · internal coherence · fidelity to the captured site).
  • render-showcase.mjsframe.mdshowcase.png (composed 16:9 frames + a 9:16 portrait section) via headless Chrome. Demo avatar/hero load from hosted URLs; overridable with --avatar / --hero.
  • reextract-design.mjs + lib/ — offline re-extract against a saved capture; shared color/font/token helpers.

Why

Turns a captured site's design system into reusable, brand-faithful video frames. Two notable pieces:

  • Accent selection rejects injected-widget strays — a candidate must be a palette member, paint a background, or recur (count≥5); otherwise it's dropped. This stopped a recurring cobalt #3860BE (a consent/focus-ring artifact) from burying real brand colors on unrelated sites.
  • Vivid secondary brand hues that live in gradients/graphics (which usage stats miss) are surfaced as accent-2 / accent-3.

How

Pure Node; reads extracted/tokens.json + design-styles.json. Every hex/size is faithful to the capture — verify-frame.mjs L2 enforces this. No new dependencies.

Test plan

  • Manual: ran capture → build → verify → render across 20+ sites (Anthropic, Linear, Stripe, HeyGen, Figma, GitLab, Aesop, Miro, Zed, …) — all pass verify-frame (L0/L1/L2 green).
  • oxlint + oxfmt clean on all scripts.
  • Unit tests (N/A — standalone toolkit scripts).

🤖 Generated with Claude Code

…wcase renderer

Toolkit that turns a `hyperframes capture` of any website into a video-first design
spec (frame.md) + a brand-dressed showcase board:
- build-frame-from-capture.mjs: capture → frame.md (palette incl. vivid brand accents,
  two type ramps, spacing, radii, shadows, video-usable components); faithful to capture
- verify-frame.mjs: L0/L1/L2 machine gates (schema, coherence, fidelity)
- render-showcase.mjs: frame.md → showcase.png (composed 16:9 frames + 9:16 portrait)
- reextract-design.mjs + lib/: offline re-extract; shared color/font/token helpers

Accent selection rejects injected-widget strays (must be a palette member, paint a bg,
or recur); vivid secondary brand hues surfaced as accent-2/3.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>

xuanruli commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

Warning

This pull request is not mergeable via GitHub because a downstack PR is open. Once all requirements are satisfied, merge this PR as a stack on Graphite.
Learn more

This stack of pull requests is managed by Graphite. Learn more about stacking.

@xuanruli

xuanruli commented Jul 7, 2026

Copy link
Copy Markdown
Contributor Author

Superseded — this toolkit belongs in experiment-framework (heygen/services/heygen_server/hyperframes/url-to-frame-md), not hyperframes. Re-homing there.

@xuanruli xuanruli closed this Jul 7, 2026
@xuanruli
xuanruli deleted the feat/url-to-frame-md branch July 7, 2026 00:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant